package com.example.yang.ministy.com.example.yang.WonderMomentFragment;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ListView;

import com.example.yang.ministy.R;
import com.example.yang.ministy.com.yang.example.adapter.MessageAdapter;

/**
 * Created by Yang on 2016/9/22.
 */
public class WonderMessageFragment extends Fragment {
private View layoutview;
    @Nullable
    @Override
    public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
        layoutview= inflater.inflate(R.layout.friend_fragment,null);
        return layoutview;

    }

    @Override
    public void onActivityCreated(@Nullable Bundle savedInstanceState) {
        super.onActivityCreated(savedInstanceState);
        if (layoutview==null) return;
        ListView listView=(ListView)layoutview.findViewById(R.id.lv2);
        listView.setAdapter(new MessageAdapter());
    }
}
